package com.keon.jianbao.bean;

import com.keon.jianbao.util.StringUtils;

/**
 * Created by keon on 2015/9/6.
 */
public class User extends Entity {

    String user_face;
    String user_name;
    String code;
    String user_hobby;
    String user_address;
    String user_mobile;
    String user_gender;

    public User(String user_face, String user_name, String user_hobby, String user_address, String user_mobile, String user_gender) {
        this.user_face = user_face;
        this.user_name = user_name;
        this.user_hobby = user_hobby;
        this.user_address = user_address;
        this.user_mobile = user_mobile;
        this.user_gender = user_gender;
    }

    public String getUser_face() {
        if (StringUtils.isEmpty(user_face) || user_face == null) {
            return "";
        } else {
            return user_face;
        }
    }

    public void setUser_face(String user_face) {
        this.user_face = user_face;
    }

    public String getUser_name() {
        return (user_name == null || StringUtils.isEmpty(user_name)) ? getUser_mobile() : user_name;
    }

    public void setUser_name(String user_name) {
        this.user_name = user_name;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getUser_hobby() {
        return user_hobby != null ? user_hobby : "";
    }

    public void setUser_hobby(String user_hobby) {
        this.user_hobby = user_hobby;
    }

    public String getUser_address() {
        return user_address != null ? user_address : "";
    }

    public void setUser_address(String user_address) {
        this.user_address = user_address;
    }

    public String getUser_mobile() {
        return user_mobile;
    }

    public void setUser_mobile(String user_mobile) {
        this.user_mobile = user_mobile;
    }

    public String getUser_gender() {
        return user_gender;
    }

    public void setUser_gender(String user_gender) {
        this.user_gender = user_gender;
    }
}
